//by 33hao invite
$(function(){
		var key = getCookie('key');
		if(key==''){
			location.href = 'login.html';
		}
		$.ajax({
			type:'post',
			url:ApiUrl+"/index.php?act=member_invite&op=getBg&type=user",
			data:{key:key},
			dataType:'json',
			//jsonp:'callback',
			success:function(result){
				document.getElementById('eweima').style.background = "url("+result.datas.bgpath+")";
				document.getElementById('eweima').style.backgroundSize = "100% 100%";
				$.ajax({
					type:'post',
					url:ApiUrl+"/index.php?act=member_invite",
					data:{key:key},
					dataType:'json',
					//jsonp:'callback',
					success:function(result){
						// checkLogin(result.login);
						$('#username').html(result.datas.member_info.user_name);
						$('#myurl').val(result.datas.member_info.myurl);
						$('#myurl_src').attr("src",result.datas.member_info.myurl_src);
						$('#avatar').attr("src",result.datas.member_info.avator);
						return false;
					}
				});
			}
		});
});